<script type="text/javascript" src="${request.contextPath}/backstage_res/ueditor/ueditor.all.min.js" charset="utf-8"></script>
<script type="text/javascript" src="${request.contextPath}/backstage_res/ueditor/ueditor.config.js" charset="utf-8"></script>
<div>
	<form method="post" id="form_${action_id}" name="form_${action_id}" enctype="multipart/form-data" >
	<input type="hidden" name="entity.channel.id" value="${channel}" />
    <table class="form-table" cellpadding=3>
        <#if channel!=3>
        	<tr>
	            <td>${action.getDatagridTitle('title')}:</td>
	            <td><input id="entity.title" name="entity.title" type="text" style="width: 400px;"  class="easyui-validatebox" data-options="required:true,validType:'length[0,64]'"   /></td>
	        </tr>
	        <tr>
	            <td>${action.getDatagridTitle('param_3')}:</td>
	            <td><input id="entity.param_3" name="entity.param_3" type="text" style="width: 400px;"  class="easyui-validatebox" data-options="required:true,validType:'length[0,64]'"   /></td>
	        </tr>
	        <tr>
	            <td>${action.getDatagridTitle('describe')}:</td>
	            <td><textarea id="entity.describe" name="entity.describe" style="height:150px;width:400px;resize: none;" type="text" class="easyui-validatebox" data-options="validType:'length[0,256]'"  /></td>
	        </tr>
	        <tr>
	            <td>${action.getDatagridTitle('icon')}:</td>
	            <td>
	            <input type="file"  name="entity.icon" id="entity_icon_${action_id}" onchange="$('#icon_filename_${action_id}').empty();$('#icon_filename_${action_id}').text(this.value);" style="display: none" />
				<a href="javascript:;;" id="icon_btn_${action_id}" onclick="$('#entity_icon_${action_id}').click();" class="easyui-linkbutton" data-options="iconCls:'icon-add'">选择文件</a>	
	    		<span id="icon_filename_${action_id}"></span>
	            </td>
	        </tr>
	        <#if channel==2>
	        <tr>
	            <td>${action.getDatagridTitle('param')}:</td>
	            <td><input id="entity.param" name="entity.param" type="text" style="width: 400px;"  class="easyui-validatebox" data-options="required:true,validType:'length[0,64]'"   /></td>
	        </tr>
	        <tr>
	            <td>${action.getDatagridTitle('param_2')}:</td>
	            <td><input id="entity.param_2" name="entity.param_2" type="text" style="width: 400px;"  class="easyui-validatebox" data-options="required:true,validType:'length[0,64]'"   /></td>
	        </tr>
	        </#if>
        </#if>
    	<#if channel!=2>
        	<tr>
	            <td>${action.getDatagridTitle('content')}:</td>
	            <td>
				<script id="ueditor_${action_id}" name="entity.content" type="text/plain" style="width:600px;height:300px">
			
	    		</script>	
	            </td>
	        </tr>
        </#if>
    </table>
	</form>
</div>
<script type="text/javascript">
    //实例化编辑器
    var ue = UE.getEditor('ueditor_${action_id}',{
    	<#if toolbars??>
    	toolbars:[[${toolbars}]],
    	</#if>
    	imageUrl:"${request.contextPath}${namespace}/mp/article/article-upload.json",//图片上传提交地址
        imagePath:"${downloadUrl?default('')}",
        imageManagerUrl:"${request.contextPath}${namespace}/mp/article/article-imageManager.json",
        imageManagerPath:"${downloadUrl?default('')}"
        });
</script>